﻿<%@ Page Title="" Language="C#" MasterPageFile="~/IndexMaster.Master" AutoEventWireup="true" CodeBehind="IndexViewCart.aspx.cs" Inherits="EHTSaleManager.IndexViewCart" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Contentmain" runat="server">
     <div class="accountInfo" style="width: 100%; float: left;">
        <div class="container">
           <div align="left" style="background:#ff6600;height:20px; padding-top:5px">
            <h1 style="font-size: 20px;color: White;font-variant: small-caps;text-transform: none;font-weight: 200;margin-bottom: 0px;padding-left:25px">Shopping Cart</h1>                      
           </div>		
			<br />            
			<asp:GridView runat="server" ID="gvShoppingCart" AutoGenerateColumns="false" EmptyDataText="Det er ingenting i handlekurven." GridLines="None" Width="100%" CellPadding="5" ShowFooter="true" DataKeyNames="ProductId" OnRowDataBound="gvShoppingCart_RowDataBound" OnRowCommand="gvShoppingCart_RowCommand">
				<HeaderStyle HorizontalAlign="Left" BackColor="Gray" ForeColor="#FFFFFF" />
				<FooterStyle HorizontalAlign="Right" BackColor="Gray" ForeColor="#FFFFFF" />
				<AlternatingRowStyle BackColor="#F8F8F8" />
				<Columns>
					<asp:BoundField DataField="Description" HeaderText="Beskrivelse" />
					<asp:TemplateField HeaderText="Antall">
						<ItemTemplate>
							<asp:TextBox runat="server" ID="txtQuantity" Columns="5" Text='<%# Eval("Quantity") %>'></asp:TextBox><br />
							<asp:LinkButton runat="server" ID="btnRemove" Text="Fjern" CommandName="Fjern" CommandArgument='<%# Eval("ProductId") %>' style="font-size:12px;"></asp:LinkButton>
						</ItemTemplate>
					</asp:TemplateField>
					<asp:BoundField DataField="UnitPrice" HeaderText="Pris" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right" DataFormatString="{0:C}" />
					<asp:BoundField DataField="TotalPrice" HeaderText="Total" ItemStyle-HorizontalAlign="Right" HeaderStyle-HorizontalAlign="Right" DataFormatString="{0:C}" />
				</Columns>
			</asp:GridView>
			<br />
			<div align = "right" style="padding:5px">
                <asp:Button runat="server" ID="btnUpdateCart" Text="Oppdatering Cart" OnClick="btnUpdateCart_Click" />
            &nbsp;<asp:Button runat="server" ID="btnPayment" Text="Betaling" 
                onclick="btnPayment_Click" />
            &nbsp;<asp:Button runat="server" ID="btnBack" Text="Tilbake" 
                onclick="btnBack_Click"/>
            </div>
        </div>
        
    </div>
</asp:Content>
